package com.easylinkin.linkappapi.grid.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.easylinkin.linkappapi.grid.entity.GridFile;
import com.easylinkin.linkappapi.grid.models.query.GridFileBatchQuery;
import com.easylinkin.linkappapi.grid.models.query.GridFileQuery;
import com.easylinkin.linkappapi.grid.models.vo.GridFileInfoVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 网格上传文件 Mapper 接口
 *
 * @author kuyujie
 * @since 2024-05-23
 */
public interface GridFileMapper extends BaseMapper<GridFile> {
    /**
     * 查询文件
     *
     * @param query
     * @return List<GridFileInfoVO>
     * @author kyj
     * @date 2024/5/23 9:51
     */
    List<GridFileInfoVO> listInfoByQuery(@Param("query") GridFileQuery query);

    /**
     * 查询文件
     *
     * @param query
     * @return List<GridFileInfoVO>
     * @author kyj
     * @date 2024/5/23 9:51
     */
    List<GridFileInfoVO> listInfoByBatchQuery(@Param("query") GridFileBatchQuery query);

    /**
     * 查询文件数量
     *
     * @param query
     * @return long
     * @author kyj
     * @date 2024/5/23 9:51
     */
    long countByQuery(@Param("query") GridFileQuery query);
}